package com.neusoft.resturant.controller;

import org.springframework.beans.factory.annotation.Autowired;

import javax.servlet.http.HttpServletRequest;

/**
 * @program: resturant
 * @description:
 * @author: lydms
 * @create: 2023-12-15 22:01
 **/


public class BaseController {

    @Autowired
    private HttpServletRequest request;

    public Long getUserId(){
        return (Long) request.getAttribute("userId");
    }


}
